﻿using Sidvall.UI.Dialogs;
using System.Threading.Tasks;

namespace Sidvall.UI.Wpf.Dialogs
{
	public class XamFileDialogManager : IFileDialog
	{
		#region Public Members

		public Sidvall.IO.IStorage Storage { get; set; }
		public string RootPath { get; set; }

		#region OpenFilesAsync

		public async Task OpenFilesAsync(OpenFileDialogContext context)
		{
			XamFileDialog dialog;

			dialog = new XamFileDialog();
			await dialog.ShowAsync(this.Storage, this.RootPath, context, Sidvall.UI.Wpf.SystemContext.Current.MainWindow);
		}

		#endregion
		#region SaveFileAsync

		public Task SaveFileAsync(SaveFileDialogContext context)
		{
			throw new System.NotImplementedException();
		}

		#endregion
		#region ToString

		public override string ToString()
		{
			return "Dialog - XamFileDialog";
		}

		#endregion

		#endregion
		#region Constructors

		public XamFileDialogManager()
		{
		}

		#endregion
	}
}
